Optimal. Leaf size=98 \[ -\frac{(2 A+C) \sin ^3(c+d x)}{3 d}+\frac{(A+C) \sin (c+d x)}{d}+\frac{A \sin ^5(c+d x)}{5 d}+\frac{B \sin (c+d x) \cos ^3(c+d x)}{4 d}+\frac{3 B \sin (c+d x) \cos (c+d x)}{8 d}+\frac{3 B x}{8} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.115202, antiderivative size = 98, normalized size of antiderivative = 1., number of steps used = 8, number of rules used = 6, integrand size = 29, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.207, Rules used = {4047, 2635, 8, 4044, 3013, 373} \[ -\frac{(2 A+C) \sin ^3(c+d x)}{3 d}+\frac{(A+C) \sin (c+d x)}{d}+\frac{A \sin ^5(c+d x)}{5 d}+\frac{B \sin (c+d x) \cos ^3(c+d x)}{4 d}+\frac{3 B \sin (c+d x) \cos (c+d x)}{8 d}+\frac{3 B x}{8} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 4047
Rule 2635
Rule 8
Rule 4044
Rule 3013
Rule 373
Rubi steps
\begin{align*} \int \cos ^5(c+d x) \left (A+B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx &=B \int \cos ^4(c+d x) \, dx+\int \cos ^5(c+d x) \left (A+C \sec ^2(c+d x)\right ) \, dx\\ &=\frac{B \cos ^3(c+d x) \sin (c+d x)}{4 d}+\frac{1}{4} (3 B) \int \cos ^2(c+d x) \, dx+\int \cos ^3(c+d x) \left (C+A \cos ^2(c+d x)\right ) \, dx\\ &=\frac{3 B \cos (c+d x) \sin (c+d x)}{8 d}+\frac{B \cos ^3(c+d x) \sin (c+d x)}{4 d}+\frac{1}{8} (3 B) \int 1 \, dx-\frac{\operatorname{Subst}\left (\int \left (1-x^2\right ) \left (A+C-A x^2\right ) \, dx,x,-\sin (c+d x)\right )}{d}\\ &=\frac{3 B x}{8}+\frac{3 B \cos (c+d x) \sin (c+d x)}{8 d}+\frac{B \cos ^3(c+d x) \sin (c+d x)}{4 d}-\frac{\operatorname{Subst}\left (\int \left (A \left (1+\frac{C}{A}\right )-(2 A+C) x^2+A x^4\right ) \, dx,x,-\sin (c+d x)\right )}{d}\\ &=\frac{3 B x}{8}+\frac{(A+C) \sin (c+d x)}{d}+\frac{3 B \cos (c+d x) \sin (c+d x)}{8 d}+\frac{B \cos ^3(c+d x) \sin (c+d x)}{4 d}-\frac{(2 A+C) \sin ^3(c+d x)}{3 d}+\frac{A \sin ^5(c+d x)}{5 d}\\ \end{align*}
Mathematica [A] time = 0.182186, size = 87, normalized size = 0.89 \[ \frac{60 (5 A+6 C) \sin (c+d x)+50 A \sin (3 (c+d x))+6 A \sin (5 (c+d x))+120 B \sin (2 (c+d x))+15 B \sin (4 (c+d x))+180 B c+180 B d x+40 C \sin (3 (c+d x))}{480 d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.054, size = 89, normalized size = 0.9 \begin{align*}{\frac{1}{d} \left ({\frac{A\sin \left ( dx+c \right ) }{5} \left ({\frac{8}{3}}+ \left ( \cos \left ( dx+c \right ) \right ) ^{4}+{\frac{4\, \left ( \cos \left ( dx+c \right ) \right ) ^{2}}{3}} \right ) }+B \left ({\frac{\sin \left ( dx+c \right ) }{4} \left ( \left ( \cos \left ( dx+c \right ) \right ) ^{3}+{\frac{3\,\cos \left ( dx+c \right ) }{2}} \right ) }+{\frac{3\,dx}{8}}+{\frac{3\,c}{8}} \right ) +{\frac{C \left ( 2+ \left ( \cos \left ( dx+c \right ) \right ) ^{2} \right ) \sin \left ( dx+c \right ) }{3}} \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 0.932985, size = 120, normalized size = 1.22 \begin{align*} \frac{32 \,{\left (3 \, \sin \left (d x + c\right )^{5} - 10 \, \sin \left (d x + c\right )^{3} + 15 \, \sin \left (d x + c\right )\right )} A + 15 \,{\left (12 \, d x + 12 \, c + \sin \left (4 \, d x + 4 \, c\right ) + 8 \, \sin \left (2 \, d x + 2 \, c\right )\right )} B - 160 \,{\left (\sin \left (d x + c\right )^{3} - 3 \, \sin \left (d x + c\right )\right )} C}{480 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 0.498851, size = 194, normalized size = 1.98 \begin{align*} \frac{45 \, B d x +{\left (24 \, A \cos \left (d x + c\right )^{4} + 30 \, B \cos \left (d x + c\right )^{3} + 8 \,{\left (4 \, A + 5 \, C\right )} \cos \left (d x + c\right )^{2} + 45 \, B \cos \left (d x + c\right ) + 64 \, A + 80 \, C\right )} \sin \left (d x + c\right )}{120 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] time = 1.16485, size = 300, normalized size = 3.06 \begin{align*} \frac{45 \,{\left (d x + c\right )} B + \frac{2 \,{\left (120 \, A \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{9} - 75 \, B \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{9} + 120 \, C \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{9} + 160 \, A \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{7} - 30 \, B \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{7} + 320 \, C \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{7} + 464 \, A \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{5} + 400 \, C \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{5} + 160 \, A \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{3} + 30 \, B \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{3} + 320 \, C \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{3} + 120 \, A \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) + 75 \, B \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) + 120 \, C \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )\right )}}{{\left (\tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{2} + 1\right )}^{5}}}{120 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]